{% extends 'base.html' %}

{% load static %}

{% block title %}{{ page.title }} - {{ site_settings.site_name }}{% endblock %}

{% block content %}
    <section class="left"
             style="background-image: url('{{ page.cover.url }}');">
    </section>
    <!-- 包含 sidebar 模板 -->
    {% include 'sidebar.html' %}
    <section class="right">
        <div class="nav_ico">
            <svg class="ham hamRotate ham1" viewBox="0 0 100 100" onclick="this.classList.toggle('active')">
                <path class="line top"
                      d="m 30,33 h 40 c 0,0 9.044436,-0.654587 9.044436,-8.508902 0,-7.854315 -8.024349,-11.958003 -14.89975,-10.85914 -6.875401,1.098863 -13.637059,4.171617 -13.637059,16.368042 v 40">
                </path>
                <path class="line middle" d="m 30,50 h 40"></path>
                <path class="line bottom"
                      d="m 30,67 h 40 c 12.796276,0 15.357889,-11.717785 15.357889,-26.851538 0,-15.133752 -4.786586,-27.274118 -16.667516,-27.274118 -11.88093,0 -18.499247,6.994427 -18.435284,17.125656 l 0.252538,40">
                </path>
            </svg>
        </div>
        <link rel="stylesheet"
              href="//cdn.jsdelivr.net/gh/highlightjs/cdn-release@9.17.1/build/styles/monokai-sublime.min.css">
        <script src="//cdn.jsdelivr.net/gh/highlightjs/cdn-release@9.17.1/build/highlight.min.js"></script>
        <script
                src="//cdn.jsdelivr.net/npm/highlightjs-line-numbers.js@2.7.0/dist/highlightjs-line-numbers.min.js"></script>
        <script>
            hljs.initHighlightingOnLoad();
            $(document).ready(function () {
                $('.wznrys pre code').each(function (i, block) {
                    hljs.lineNumbersBlock(block);
                });
            });
        </script>
        <div class="right_box">
            <div class="single_info_box">
                <h1 class="single_title">{{ page.title }}</h1>
            </div>
            <div class="wznrys">
                {{ page.content|safe }}
            </div>


        </div>
        <!-- 包含 foot 模板 -->
        {% include 'foot.html' %}
    </section><!--right-->
{% endblock %}

{% block extra_foot %}
    <script type="text/javascript" id="ajax-comment-js-extra">
        /* <![CDATA[ */
        var ajaxcomment = {
            "ajax_url": "https:\/\/cux.huitheme.cn\/wp-admin\/admin-ajax.php",
            "order": "asc",
            "formpostion": "bottom"
        };
        /* ]]> */
    </script>

    <script type="text/javascript" src="{% static 'js/app.js' %}" id="ajax-comment-js"></script>
{% endblock %}
